﻿using System;
using System.Collections.Generic;
using AnimeWebCrawler;
using System.IO;
using System.Net;
using HtmlAgilityPack;

namespace ConsoleAplication1
{
    class Program
    {
        static void Main(string[] args)
        {
            WebCrawler d = new WebCrawler();
            d.LoadHost("http://localhost/main/");
            d.SetXPath("//table[@width='100%' and @class='anm']//a[@href]");
            d.LinkCollect();
            Console.ReadKey();/*
            HttpWebRequest request = (HttpWebRequest)WebRequest.Create("http://localhost/main/");
            HttpWebResponse response = (HttpWebResponse)request.GetResponse();
            StreamReader PageSR = new StreamReader(response.GetResponseStream());
            string Page = PageSR.ReadToEnd();
            PageSR.Close();
            HtmlAgilityPack.HtmlDocument MainPage = new HtmlAgilityPack.HtmlDocument();
            MainPage.LoadHtml(Page);
            var Node = MainPage.DocumentNode.SelectNodes("//table[@width='100%' and @class='anm']//a[@href]");
            Console.ReadKey();*/
       }
    }
}
